<?php

class SystemAction extends CommonAction {
	//系统信息
    public function index(){
    	$userModel = M('User');
    	
    	$userInfo = $userModel->where(array('admin_id'=>session('userid')))->select();
    	
    	$this->loginNum = $userInfo[0]['admin_login'];
    	$this->loginIP = $userInfo[0]['admin_modify_ip'];
    	$this->loginTime = $userInfo[0]['admin_modify_date'];
    	
    	//服务器信息
    	$this->sysType = php_uname('s');
    	$this->phpVersion = $_SERVER['SERVER_SOFTWARE'];
    	$this->mysqlVersion = mysql_get_server_info();
    	
        $this->display();
    }
    //基本设置
    public function basic(){
    	$infoShow = $this->_get('info');
    	if(!empty($infoShow)){
    		$this->info = $this->_get('info');
    	}else{
    		$this->info = 1;
    	}
    	$this->display();
    }
    //语言设置
    public function lang(){
    	$this->display();
    }
    //数据与安全
    public function safe(){
    	$this->display();
    }
}